package feizhou.consumerdemo.business.controller.feign;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import feizhou.consumerdemo.business.bean.User;
import feizhou.consumerdemo.business.feign.UserFeign;

/**
 * 描述该类- JPA
 *
 * @author zhoufei
 * @class: UserController
 * @date 2020/12/4 15:13
 * @Verson 1.0 -2020/12/4 15:13
 * @see
 */
@RestController
@RequestMapping("/feign")
public class UserFeignController {
    
    @Autowired
    private UserFeign userFeign;
    
    @GetMapping("/{id}")
    public User queryById(@PathVariable Long id) {
        return userFeign.queryById(id);
    }
}
